a = '123'
b = u'123'

print isinstance(a, basestring)
print isinstance(a, str)
print isinstance(a, unicode)
print isinstance(b, basestring)
print isinstance(b, (str, unicode))
